//*****************************************************************************
//**************** (C) 2008 by Eleven Engineering Incorporated ****************
//*****************************************************************************
//**
//**		Tabs:	This file looks best with tab stops set every 6 spaces.
//**
//*****************************************************************************
//*****************************************************************************
//**
//** File:		common_data.asm
//** Project:	Simple Sample Project for WHAM4 Alpha
//** Revised:	
//**
//** Description:	
//**
//*****************************************************************************
//*****************************************************************************

//-------------------------------------------------------
// XInC2 I/O Cell Configuration Table
//
// The following I/O cell configuration must configure the I/O for the system and application.
// See the Technical specification for more info.
//		Bit		Function		Meaning when 1
// ______________________________________________________
//		0		SR			fast slew
//		1		E2			+2ma drive strength
//		2		E4			+4ma drive strength
//		3		E8			+8ma drive strength
//		4		SMT			Schmitt Trigger input
//		5		PU/PD select	Pull up
//		6		PU/PD enable	enabled
// ______________________________________________________
IOCbase:
// 00 = Default of 0b1000011
iPA:	0b0000010		// PA			0
iPB0:	0b0000011		// PB0		1
iPB1:	0b0000011		// PB1		2
iPB2:	0b1100011		// PB2		3
iPC0:	00			// PC0		4
iPC1:	00			// PC1		5
iPC2:	00			// PC2		6
iPC3:	00			// PC3		7
iPC4:	0b1100011		// PC4 		8
iPC5:	00			// PC5 		9
iPC6:	0b1100011		// PC6 		10
iPC7:	0b1100011		// PC7		11
iPD0:	0b0000101		// PD0  MISO1	12
iPD1:	00			// PD1  MOSI1	13
iPD2:	00			// PD2  SCK1	14
iPD3:	00			// PD3  SEN0  	15
iPD4:	00			// PD4  TMRA0  	16
iPD5:	00			// PD5  TMRA1	17
iPD6:	00			// PD6  TMRA2	18
iPD7:	00			// PD7  TMRA3	19
#if	_RFLM_implementation == 0x0003
iPE:	0b1001111		// PE			20
#else
iPE:	0b1000101		// PE			20
#endif
iPF:	0b1100011		// PF			21
iPG0:	0b1110011		// PG0  MISO0	22
iPG1:	00			// PG1  MOSI0	23
iPG2:	00			// PG2  SCK0 	24
iPG3:	00			// PG3  SEN0    	25
iPH:	0b0010000		// PH	  BBU0	26
iPI:	0b1100011		// PI   BBU1	27
iPJ:	0b0010011		// PJ   DASI 	28
iTMRB:0b0000011		// TMRB1		29
IOClen	= @ - IOCbase


VersionString:
	"Sample Project Ver"
	_majorVersion + 0x30
	"."
	_minorVersion + 0x30
	"."
	_developmentVersion + 0x30
	CR, LF, EOS	

MSG_NEWLINE: CR,LF,EOS
MSG_tab:
	"	",EOS


DebugPoint: "we got here",CR,LF,EOS

//RFLP_MstrSessionID
//	Randomly generated ID used as part of a challenge-response protocol to
//	establish a connection between a master and slave
//	This ID is used to prevent slave response collisions when there are devices
//	with dynamic ChannelIDs

RFLP_MstrSessionID:				@ = @ + 1		//12 bit
RFLP_MstrSessionID_ChallengeResponse:	@ = @ + 1
RFLP_SlvSessionID:				@ = @ + 1
RFLP_Slv_ChallengeResponse:			@ = @ + 1

RFhopSequence_pntr:		@ = @ + 1

//This variable is used if multiple threads access the SCUstop register
//The SCUstop register is write only so this variable can be used to
//mirror the state of the SCUstop register.  Use this along with 
//a semaphore when starting/stopping threads
	SCUstop_status:		@ = @ + 1


	Counter:			@ = @ + 1
	CounterFlag:		@ = @ + 1
	LEDstate:			@ = @ + 1
	Result:			@ = @ + 1
	receivedData:		@ = @ + 1
	
	 getPacket_timeout_BBUticks:		@ = @ + 1
	